<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
</head>
<body>
    <script>
    //变量的声明 ，赋值
    var age = 11;
    var name = 'zzq';
    var address = '河南省郑州市中原区';
    var id = 001;
    var sex = '男' ;
    //弹出警示框    字符串的拼接
    alert('我是'+name+',我今年'+age+'岁了，我的ID是'+id+'号，我的性别是'+sex+'，我的地址是'+address);
    alert('我是'+name+'，我来自'+address+'我今年'+age+'岁了，我的id是'+id+'我的性别是'+sex);
    alert('大家好，我是'+name+'我的ID是'+id+'号，我是'+sex+'生，我来自'+address+'我今年'+'岁了');
    //isNAN
    var result1 = isNaN(12);
    var result2 = isNaN('七里香');
    alert(result1);
    alert(result2);
    var result1 = isNaN(35);
    var result2 = isNaN('晴天');
    alert(result1);
    alert(result2);
    var result1 = isNaN(18);
    var result2 = isNaN('搁浅');
    alert(result1);
    alert(result2);
    var result1 = isNaN(20);
    var result2 = isNaN('一路向北');
    alert(result1);
    alert(result2);
    //交换两个变量值
    var name1 = '张三';
    var name2 = '李四';
    var name3 = name1;
    var name1 = name2;
    var name2 = name3;
    alert(name1+name2);
    
    var name1 = '王五';
    var name2 = '赵六';
    var name3 = name1;
    var name1 = name2;
    var name2 = name3;
    alert(name1+name2);

    var name1 = '劫';
    var name2 = '泰隆';
    var name3 = name2;
    var name2 = name1;
    var name1 = name3;
    alert(name1+name2);

    var name1 = '盖伦';
    var name2 = '诺手';
    var name3 = name2;
    var name2 = name1;
    var name1 = name3;
    alert(name1+name2);
    //字符串拼接加强
    var a = '在山腰间飘逸的红雨\n',
        b ='随着北风凋零,我轻轻摇曳风铃\n',
        c ='想唤醒被遗弃的爱情\n',
        d ='雪花已铺满了地\n',
        e ='深怕窗外枫叶已结成冰';
       alert(a+b+c+d+e);
    </script>
</body>
</html>